<template>
  <div class="hello">
    {{mmg}}
    <input type="text" v-model="mmg" />
    <br>
    <button v-on:click="handleSendOne">发送登录请求</button>
  </div>
</template>

<script>
import axios from 'axios';

export default {
  name: 'MyTest',
  props: {
    msg: String
  },
  data(){
    return{
      mmg: 'MyTest',
      password: '1110'
    }
  },
  methods:{
    handleSendOne(){
      axios({
        url: '/api/admin/employee/login',
        method: 'post',
        data: {
          username: 'admin',
          password: '123456'
        }
      }).then(res => {
        console.log(res.data)
      })
    }
  }
}
</script>

<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
h3 {
  margin: 40px 0 0;
}
ul {
  list-style-type: none;
  padding: 0;
}
li {
  display: inline-block;
  margin: 0 10px;
}
a {
  color: #42b983;
}
</style>
